import viewer from './viewer';

function getQueryVariable(variable) {
  var query = window.location.search.substring(1);
  var vars = query.split('&');
  for (var i = 0; i < vars.length; i++) {
    var pair = vars[i].split('=');
    if (pair[0] == variable) {
      return pair[1];
    }
  }
  return false;
}
/**
 * 通过url的 ?file=xxx.pdf 参数，可以覆盖defaultPdf
 */
const defaultPdf =
  'https://mozilla.github.io/pdf.js/web/compressed.tracemonkey-pldi-09.pdf';

viewer(defaultPdf);
